import { createRouter, createWebHistory } from 'vue-router'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: "/",
      redirect: '/home'
    },
    {
      path: "/home1",
      name: '/home1',
      component: () => import('../views/AboutView.vue')
    },
    {
      path: '/login',
      name: 'login',
      component: () => import('../views/Login/Login.vue')
    },
    {
      path: '/home',
      name: 'home',
      component: () => import('../views/Home/Home.vue')
    },
    {
      path: '/work',
      name: 'work',
      component: () => import('../views/Work/Work.vue')
    },
    {
      path: '/protect',
      name: 'protect',
      component: () => import('../views/Protect/Protect.vue')
    },
    {
      path: '/equipment',
      name: 'equipment',
      component: () => import('../views/Equipment/Equipment.vue')
    },
    {
      path: '/:pathMatch(.*)*',
      name: 'NotFound',
      component: () => import('../views/Error/Error.vue')
    },
  ]
})

export default router
